Feat: Deploy to the VM after every merge to main #70
+173
−10
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
After the checks pass on a push to main, the CI job copies the built frontend to /var/www/html/project2, installs the built backend with its production dependencies in /srv/ufound-it and restarts the ufound-it-backend systemd service. It then calls the health query through Apache and fails if the backend does not answer.
The backend runs outside the runner's work folder because the next CI run wipes it. Runs on main are no longer cancelled, so a deploy is not stopped halfway. Pull requests still stop after the checks.
The service, sudoers rule and Apache proxy are in deploy/, and the one-time VM setup is documented in docs/ci-cd.md. AGENTS.md now has the VM address and how deploying works.
Closes #68